HTTP Request - Delivery Script

This feature allows you to send and receive SMS via HTTP request even from a server that is not directly connected to a GSM modem, but is connected to another IceWarp Server that is. Sending messages from such a server was possible (provided that there was a gateway defined on this sending server), but receiving not.

The new delivery script lets you to define a rule for incoming messages (on the server connected to a modem):

Condition: All messages

Action: Execute application

for application set:

Executable: http://yourserver.com/sms/deliver.html?id=HTTP&pass=pinnumber&number=%from%3&data=%data%

Type: URL

executable_dialog

This URL for SMS delivery requires the following URI variables:

  • id ID of the gateway to deliver the message via
  • pass gateway password (matches the PIN number)
  • number number of the SMS sender
  • data data of the sms sender (UTF-8)
  • binary 0/1 boolean telling whether data is in binary format, no use for that currently
  • yourserver the server that is not connected to a modem

The only other necessary thing is to add a user on the server with a modem (either a usual one or within the SMS – Users tab) and pass the URI variables.

Scenario : SMS "Provider" Is another IceWarp Server

Say, you have one IceWarp Server (server A) without a modem and with a SMS HTTP gateway defined. The second IceWarp Server (server B) uses a modem.

How to set these servers the users to be able to send SMS and obtain answers:

Server A:

Create a SMS HTTP gateway (SMS Service ? General) pointing to server B. Use settings similar to the ones in the figure:

Server B:

Create a rule for incoming messages (SMS Service ? Incoming Messages). This rule will direct SMS answers to server A users. Use settings similar to the ones in the figure:

Syntax:

http://[server_A_IP_address]/sms/deliver.html?id=58&number=%%from_alias%%&data=%%body%%&pass=1234567

where:

id ? ID of the SMS gateway (24 in the first figure),

pass ? PIN/Password of the gateway (1234567 here).

All the parameters are obligatory.